Ext.namespace("org.microsite.deployment");

Deployment.prototype.getType = function() {return 'Deployment';};

org.microsite.util.ViewRegistry.add(new org.microsite.util.ViewHelper({
    type : Deployment,
    service : DeploymentRemote,
    editor : org.microsite.deployment.DeploymentEditor,
    template : new Ext.XTemplate('<table border="0" cellspacing="5">',
            '<tr><td><b>Name</b></td><td>{name}</td></tr>',
            '<tr><td><b>Description</b></td><td>{description}</td></tr>',
            '<tr><td><b>Server</b></td><td>{server}</td></tr>',
            '<tr><td><b>Database</b></td><td>{database}</td></tr>',
            '<tr><td><b>Project</b></td><td>{project}</td></tr>',
            '<tr><td><b>Admin</b></td><td>{admin}</td></tr>',
            '</table>'),
    fields : [{name:'id'},{name:'name'},{name:'description'},{name:'server'},{name:'database'},
                {name:'project'},{name:'admin'},{name:'code'}],
    
    getFetchMethods : function() {
        return [this.fetchServer, this.fetchHost, this.fetchAdmin, this.fetchDatabase, this.fetchProject];
    }
}));
